import {  View, Image,Text } from "@tarojs/components";
import { Fragment, useState } from "react";
import "./issuesDetail.scss";

// import CustomNavBar from "@/component/CustomNavBar";
import good_img from "@/static/images/auth/good.png";
import bad_img from "@/static/images/auth/bad.png";

import { useLoad,  } from "@tarojs/taro";

definePageConfig({
  navigationBarTitleText: "问题详情",
});
export default function IssuesDetail() {
  const [issueName, setIssueName] = useState('')
  const [issueAnswer, setIssueAnswer] = useState('')

  useLoad((opsetion) => {
    setIssueName(opsetion.issueName)
    setIssueAnswer(opsetion.issueAnswer)
  })
  const fix = (e) => {
    
  }
  return (
    <Fragment>
      {/* <CustomNavBar title="问题详情"></CustomNavBar> */}
      <View className="container" style={{ padding: '0 20rpx' }}>
        <View className="issueName">问题名称:&nbsp;&nbsp;{issueName}</View>
        <View className="issueAnswer">{issueAnswer}</View>
      </View>
      <View className="footer">
        <View className="btn" onClick={() => fix(1)}><Image src={good_img} mode='widthFix' className='icon_global'></Image>&nbsp;已解决</View>
        <View className="btn" style={{border:'2rpx solid #676978', color:'#676978'}} onClick={() => fix(0)}><Image src={bad_img} mode='widthFix' className='icon_global' ></Image><Text>&nbsp;未解决</Text></View>
      </View>
    </Fragment>
  )

}
